<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
    /* 1.float  float:left  元素靠左浮动
       2.float  float:right 元素靠右浮动
       3.float  float:none  元素不浮动
       浮动的作用1:定义网页中其他文本如何环绕该元素显示（文字环绕图片）
       浮动的作用2:就是让竖着的东西横着来 */
        div{
            width: 100px;
            height: 100px;
        }
        .red{
            background-color: red;
            /* width: 900px;
            height: 900px; */
            float: left;
            /* float: right;  */
        }
        .green{
            background-color: green;
            float: left;
            /* float: right; */
            /* width: 300px;
            height: 300px; */
        }
        .blue{
            background-color: blue;
            float: left;
            /* float: right; */
        }

    </style>
</head>
<body>
    <div class="red"></div>
    <div class="green"></div>
    <div class="blue"></div>
</body>
</html>